package net.chenyan.server.dto;/**
 * @author chenyan
 * @createTime 2022/3/24 15:31
 * @description description
 */

import cn.hutool.core.bean.BeanUtil;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import net.chenyan.server.po.User;

/**
 *@description: TODO
 *@author: chenyan
 *@create: 2022/3/24 15:31
 */
@Data
public class UserAddDTO {

    /**
    * 用户昵称
     */
    @ApiModelProperty(value = "用户昵称", dataType = "String")
    private String name;

    /**
     * 电话号码
     */
    @ApiModelProperty(value = "电话号码", dataType = "int")
    private String tel;

    /**
     * 密码
     */
    @ApiModelProperty(value = "密码", dataType = "String")
    private String password;

    /**
     * 头像
     */
    @ApiModelProperty(value = "头像", dataType = "String")
    private String portrait;

    /**
     * 个性签名
     */
    @ApiModelProperty(value = "个性签名", dataType = "String")
    private String signature;

    public User toUser() {
        User user = new User();
        BeanUtil.copyProperties(this, user);
        return user;}
}
